package com.gitee.xhs.keyedState.valueState;

import org.apache.flink.api.common.state.ValueStateDescriptor;
import org.apache.flink.api.common.typeinfo.TypeInformation;

import static com.gitee.xhs.StateConstant.FLINK_CHECK_POINT_PATH;

/**
 * @author BigHead
 * @date 2022/6/29 10:06
 * @description ValueStateConstant
 */
public class ValueStateConstant {

    public static final String CUSTOM_VALUE_STATE_DIR = "valueState/";

    public static final String VALUE_STATE_PATH = FLINK_CHECK_POINT_PATH + CUSTOM_VALUE_STATE_DIR;
    public static final String VALUE_STATE_UID = "value-state-uid";
    public static final String VALUE_STATE_NAME = "value-state";
    public static final ValueStateDescriptor<Integer> VALUE_STATE_DESCRIPTOR = new ValueStateDescriptor<>(
            VALUE_STATE_NAME,
            TypeInformation.of(Integer.class)
    );

}
